<h1>评论</h1>

<%= error_messages_for :productcomment %>
<p>请你对订单<%=@order.id%>中的<%=link_to @product.title,:controller=>:products,:action=>:show,:id=>@product.id%>进行评论！</p>
<% form_for(@productcomment,:url=>{:action=>:create,:order_id=>params[:order_id],:product_id=>params[:product_id]}) do |f| %>
  <p>
    <b>评论内容</b><br />
    <%= f.text_area :content%>
  </p>

  <p>
    <b>你给这件商品的评分是（1-5）分</b><br />
    <%= f.text_field :range %>
  </p>

  <p>
    <%= f.submit "发表评论" %>
  </p>
<% end %>
